LotusScript Doc

Class: LSAAddrUnit

Represents a contact person or an organizational unit. This class corresponds to the forms LSAContact and LSAOrganization in the LSAAddress application.

Version:
1.2.3, 25.JUL.2000 <BR>
History:
25.JUL.2000RGRSaveToPredefinedFields changed
25.JUL.2000RGRconstructor changed to determine unitType from document
08.JUN.2000RGRDelete method modified to delete child objects and check out object in instance manager
31.MAY.2000RGRmethods saveToPredefinedFields and Save changed



Property Summary
Public Property Set AddressData As LSAAddressData
Public Property Get AddressData As LSAAddressData
Public Property Get AddrMgr As Variant
Public Property Set AddrMgrID As String
Public Property Get AddrMgrID As String
Public Property Set CampaignS As Variant
Public Property Get CampaignS As Variant
Public Property Set ContextDoc As NotesDocument
Public Property Get ContextDoc As NotesDocument
Public Property Set DocID As String
Public Property Get DocID As String
Public Property Set GlossaryReferenceS As LSAGlossaryReferenceS
Public Property Get GlossaryReferenceS As LSAGlossaryReferenceS
Public Property Set OrganizationData As LSAAddrOrganizationData
Public Property Get OrganizationData As LSAAddrOrganizationData
Public Property Set PersonData As LSAAddrPersonData
Public Property Get PersonData As LSAAddrPersonData
Public Property Set SyncInfo As LSASync
Public Property Get SyncInfo As LSASync
Public Property Get UnitInstanceID As String
Public Property Set UnitType As String
Public Property Get UnitType As String

Method Summary
Sub Delete ()
Function getCustomerContactSearchCriterias () As Variant
Function getCustomerDataField (fieldname As String) As Variant
Function getCustomerOrganizationSearchCriterias () As Variant
Function getCustomerSerialData () As String
Function getDisplayName () As String
Function getOrganizationData () As String
Function getOrganizationS () As Variant
Function getPersonData () As String
Function getReference () As String
Sub New (doc As NotesDocument, unitType As String, addrMgrID As String)
Sub Save ()
Function SaveToPredefinedFields () As Integer
Sub setCustomerContactSearchCriterias (newCriterias As Variant)
Sub SetCustomerDataField (field As String, value As Variant)
Sub setCustomerOrganizationSearchCriterias (newCriterias As Variant)
Sub setCustomerSerialData (newData As String)

Property Detail

Public Property Set ContextDoc AsNotesDocument

Sets the document which corresponds to this unit.

Summmary Top

Public Property Get ContextDoc AsNotesDocument

Summmary Top

Public Property Set DocID AsString

Sets the document which corresponds to this unit.

Summmary Top

Public Property Get DocID AsString

Summmary Top

Public Property Set UnitType AsString

Sets the type of the unit: "LSAContact" for a contact unit "LSAOrganization" for an organization unit If the type doesn't much one of the options the default is Organization

Summmary Top

Public Property Get UnitType AsString

Summmary Top

Public Property Get UnitInstanceID AsString

Summmary Top

Public Property Set AddrMgrID AsString

The id with which the LSAAddressManager has been checked in in the InstanceManager.

Summmary Top

Public Property Get AddrMgrID AsString

Summmary Top

Public Property Get AddrMgr AsVariant

Returns a handle to the address manager object

Summmary Top

Public Property Set PersonData AsLSAAddrPersonData

Summmary Top

Public Property Get PersonData AsLSAAddrPersonData

Summmary Top

Public Property Set OrganizationData AsLSAAddrOrganizationData

Summmary Top

Public Property Get OrganizationData AsLSAAddrOrganizationData

Summmary Top

Public Property Set AddressData AsLSAAddressData

Summmary Top

Public Property Get AddressData AsLSAAddressData

Summmary Top

Public Property Set GlossaryReferenceS AsLSAGlossaryReferenceS

Summmary Top

Public Property Get GlossaryReferenceS AsLSAGlossaryReferenceS

Summmary Top

Public Property Set SyncInfo AsLSASync

Summmary Top

Public Property Get SyncInfo AsLSASync

Summmary Top

Public Property Set CampaignS AsVariant

Sets the array of campaign in which the unit is member in

Summmary Top

Public Property Get CampaignS AsVariant

Summmary Top
Method Detail

New

Public Sub New(doc As NotesDocument,unitType As String,addrMgrID As String)
Instantiates a new object by filling the unit with the information from the context document. If a document is provided the unitType is determined by the document values. If doc has the value nothing the parameter unitType determines the type of the new unit.

Parameters:
docNotesDocumentthe document storing the persintant data of the unit
unitTypeStringLSAContact or LSAOrganization depending on the type of unit
addrMgrIDStringhandle to access the LSAAddressManager through the InstanceManager
History:
25.JUL.2000RGRif doc isn't nothing than the constructor determines the unitType
Summmary Top

Delete

Public Sub Delete
Default destructor of the class. Deletes all child objects and checks out the object in the instance manager.

History:
08.JUN.2000RGRDelete the children and check out
Summmary Top

getPersonData

Public Function getPersonData As String
Returns the Block "LotusC" if the unit is a contact. Otherwise an empty string is returned.

Returns:
Stringa value of the form ##LotusC#FirstName#...
See also:
LSALibAddrPersonData#LSAAddrPersonData#getPersonData
Summmary Top

getOrganizationData

Public Function getOrganizationData As String
Returns the Block "LotusC" if the unit is a contact. Otherwise an empty string is returned.

Returns:
Stringa value of the form ##LotusC#FirstName#...
See also:
LSALibAddrOrganizationData#LSAAddrOrganizationData#getOrganizationData
Summmary Top

getDisplayName

Public Function getDisplayName As String
Summmary Top

getOrganizationS

Public Function getOrganizationS As Variant
Returns an array of all organization a unit is member of

Returns:
Variantarray with all organizations of a unit
Summmary Top

getReference

Public Function getReference As String
Returns a serial data string consisting of the name of the organization or person and the internal ID. E.g. ##Boss Betram B#A3243490D63545342

Summmary Top

getCustomerContactSearchCriterias

Public Function getCustomerContactSearchCriterias As Variant
Returns the contact search criterias which have been specified by a customer. This function is called from the class LSAAddressData and the values are appended to the property ContactSearchCriterias of LSAAddressData.

Summmary Top

setCustomerContactSearchCriterias

Public Sub setCustomerContactSearchCriterias(newCriterias As Variant)
Sets the contact search criterias specific to the customer. This values are added to the property ContactSearchCriterias of the class LSAAddressData.

Parameters:
newCriteriasVariantString array of possible search criterias
Summmary Top

getCustomerOrganizationSearchCriterias

Public Function getCustomerOrganizationSearchCriterias As Variant
Returns the organization search criterias which have been specified by a customer. This function is called from the class LSAAddressData and the values are appended to the property ContactSearchCriterias of LSAAddressData.

Summmary Top

setCustomerOrganizationSearchCriterias

Public Sub setCustomerOrganizationSearchCriterias(newCriterias As Variant)
Sets the organization search criterias specific to the customer. This values are added to the property OrganizationSearchCriterias of the class LSAAddressData.

Parameters:
newCriteriasVariantString array of possible search criterias
Summmary Top

getCustomerSerialData

Public Function getCustomerSerialData As String
Returns the serial data string which is specific to a customer and is added to the DefaultData property of the class LSAAddressData. This function is called by the class LSAAddressData!

Returns:
Stringserialdata with customer data
Summmary Top

setCustomerSerialData

Public Sub setCustomerSerialData(newData As String)
Sets the serial data string specific to the customer which is added to the property DefaultData of the class LSAAddressData.

Parameters:
newDataStringSerialDataString which must use the Delimiter of the class LSAAddressData.
Summmary Top

Save

Public Sub Save
Saves the unit to the NotesDocument ContextDoc by using the save routines of the underlying objects. If CustomerDataFields are set the unit saves the document disregarding the fact that maybe no changes have been taken place.

See also:
LSALibPostalAddresseS_LSAPostalAddresseS#setAutoRefreshed
LSALibPostalAddresseS_LSAPostalAddresseS#recalcCorrespondence
History:
31.MAY.2000methodsetAutoRefreshed used to disable not neccessary computations of the correspondence functionality this is inserted for performance reasons
Summmary Top

SaveToPredefinedFields

Public Function SaveToPredefinedFields As Integer
Save attributes to predefined fields. The fieldnames correspond to the forms LSAContact and LSAOrganization in LSB-Address

Returns:
booleantrue, if a field in the document has been changed
History:
25.JUL.2000RGRfieldname DocType changed to LSADocType
24.JUL.2000RGRwrite LSC-fields to disk
31.MAY.2000RGRtemporary variable to access getDisplayName function only once
Summmary Top

SetCustomerDataField

Public Sub SetCustomerDataField(field As String,value As Variant)
Set the data for a free data field as specified by the customer. If this function is used and the save routine is called then the document is saved even if no changes has taken place.

Parameters:
FieldStringthe fieldname of the field to be set
ValueStringthe value set into the field
Summmary Top

getCustomerDataField

Public Function getCustomerDataField(fieldname As String) As Variant
Get the data from a free data field as specified by the customer

Parameters:
fieldnameStringthe name of the field to be read
Returns:
Variantthe value found in the field
Summmary Top

TopLotusScript Doc
© Lotus Professional Services
generated on : 05-Apr-01 8:45:33 AM